package com.swh.listener;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @Author: swh
 * @Description:
 * @Date: 2021/1/15 17:01
 * @Version: 1.0
 */
@Component
@RabbitListener(queues = "xiaoming")
public class Consumer3 {

    @RabbitHandler
    public void receiveMsg(String msg){
        System.out.println("xiaoming收到信息"+msg);
    }
}
